package com.xwd.pojo;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @ClassName Book
 * @Description: com.xwd.servlet.pojo
 * @Auther: xiwd
 * @Date: 2022/2/13 - 02 - 13 - 13:10
 * @version: 1.0
 */
public class Book implements Serializable {
    private static final long serialVersionUID = 4371096892184562638L;
    //properties
    private Integer id;
    private String name;
    private String author;
    private Date publish;
    private BigDecimal price;
    private String typeid;

    //setter
    public void setId(Integer id) {
        this.id = id;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public void setPublish(Date publish) {
        this.publish = publish;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public void setTypeid(String typeid) {
        this.typeid = typeid;
    }

    //getter
    public Integer getId() {
        return id;
    }

    public String getName() {
        return name;
    }

    public String getAuthor() {
        return author;
    }

    public Date getPublish() {
        return publish;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public String getTypeid() {
        return typeid;
    }

    //constructors

    public Book() {
        this(null,null,null,null,null,null);
    }

    public Book(Integer id, String name, String author, Date publish, BigDecimal price, String typeid) {
        super();
        this.id = id;
        this.name = name;
        this.author = author;
        this.publish = publish;
        this.price = price;
        this.typeid = typeid;
    }
    //methods
    @Override
    public String toString() {
        return "Book{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", author='" + author + '\'' +
                ", publish=" + publish +
                ", price=" + price +
                ", typeid='" + typeid + '\'' +
                '}';
    }
}
